{
  "nbformat": 4,
  "nbformat_minor": 0,
  "metadata": {
    "colab": {
      "provenance": [],
      "machine_shape": "hm",
      "gpuType": "T4",
      "authorship_tag": "ABX9TyNyZLBAb4rz798gJ98/mSRn",
      "include_colab_link": true
    },
    "kernelspec": {
      "name": "python3",
      "display_name": "Python 3"
    },
    "language_info": {
      "name": "python"
    },
    "accelerator": "GPU",
    "widgets": {
      "application/vnd.jupyter.widget-state+json": {
        "9b4a0d135cc7499781556b0ec85c5f06": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "VBoxModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "VBoxModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "VBoxView",
            "box_style": "",
            "children": [
              "IPY_MODEL_31ca4156cbf4489db49f91bcae1e3d7d",
              "IPY_MODEL_a499455b548f4d519dc2975ff2dbfe0d",
              "IPY_MODEL_24d269e4b5e241b3bad94ccf505a2881",
              "IPY_MODEL_5a2e61a5bf9f4f24806dc95968ce1008"
            ],
            "layout": "IPY_MODEL_cd098ea148e543d49f01032218c1b3a1"
          }
        },
        "3c8886b7d7fb49469ec915052b00bf5d": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "HTMLModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "HTMLModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "HTMLView",
            "description": "",
            "description_tooltip": null,
            "layout": "IPY_MODEL_355cebaa4f73413787892d42916277c9",
            "placeholder": "​",
            "style": "IPY_MODEL_30968e114015454ea4eaa790252cdb41",
            "value": "<center> <img\nsrc=https://huggingface.co/front/assets/huggingface_logo-noborder.svg\nalt='Hugging Face'> <br> Copy a token from <a\nhref=\"https://huggingface.co/settings/tokens\" target=\"_blank\">your Hugging Face\ntokens page</a> and paste it below. <br> Immediately click login after copying\nyour token or it might be stored in plain text in this notebook file. </center>"
          }
        },
        "3012321eee314d02b4a88a9b701ffcde": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "PasswordModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "PasswordModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "PasswordView",
            "continuous_update": true,
            "description": "Token:",
            "description_tooltip": null,
            "disabled": false,
            "layout": "IPY_MODEL_f9f56b8daf0340379a2509a3686ccb83",
            "placeholder": "​",
            "style": "IPY_MODEL_3fee9bb5c9e8474094cbf36aa5328664",
            "value": ""
          }
        },
        "97f905a891584085bd98221eb4b22c8f": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "CheckboxModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "CheckboxModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "CheckboxView",
            "description": "Add token as git credential?",
            "description_tooltip": null,
            "disabled": false,
            "indent": true,
            "layout": "IPY_MODEL_9985cc92f11b42b48334087856a47c62",
            "style": "IPY_MODEL_5994dc90d66844f6bf4bde53138cfeff",
            "value": true
          }
        },
        "390243471666419d865868c74b688178": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "ButtonModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "ButtonModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "ButtonView",
            "button_style": "",
            "description": "Login",
            "disabled": false,
            "icon": "",
            "layout": "IPY_MODEL_51c83fb9a8484be898b0d86fd29aeb4e",
            "style": "IPY_MODEL_e9d4ff818d1d4aed8b0ac9a5e2a94c11",
            "tooltip": ""
          }
        },
        "22d20e2452a14f7683a768ae80eff429": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "HTMLModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "HTMLModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "HTMLView",
            "description": "",
            "description_tooltip": null,
            "layout": "IPY_MODEL_0f7037f8d36648598c0798e4af1461d1",
            "placeholder": "​",
            "style": "IPY_MODEL_8760a6faea414090a4ae168df353f9aa",
            "value": "\n<b>Pro Tip:</b> If you don't already have one, you can create a dedicated\n'notebooks' token with 'write' access, that you can then easily reuse for all\nnotebooks. </center>"
          }
        },
        "cd098ea148e543d49f01032218c1b3a1": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": "center",
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": "flex",
            "flex": null,
            "flex_flow": "column",
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": "50%"
          }
        },
        "355cebaa4f73413787892d42916277c9": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "30968e114015454ea4eaa790252cdb41": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "DescriptionStyleModel",
          "model_module_version": "1.5.0",
          "state": {
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "DescriptionStyleModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "StyleView",
            "description_width": ""
          }
        },
        "f9f56b8daf0340379a2509a3686ccb83": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "3fee9bb5c9e8474094cbf36aa5328664": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "DescriptionStyleModel",
          "model_module_version": "1.5.0",
          "state": {
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "DescriptionStyleModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "StyleView",
            "description_width": ""
          }
        },
        "9985cc92f11b42b48334087856a47c62": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "5994dc90d66844f6bf4bde53138cfeff": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "DescriptionStyleModel",
          "model_module_version": "1.5.0",
          "state": {
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "DescriptionStyleModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "StyleView",
            "description_width": ""
          }
        },
        "51c83fb9a8484be898b0d86fd29aeb4e": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "e9d4ff818d1d4aed8b0ac9a5e2a94c11": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "ButtonStyleModel",
          "model_module_version": "1.5.0",
          "state": {
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "ButtonStyleModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "StyleView",
            "button_color": null,
            "font_weight": ""
          }
        },
        "0f7037f8d36648598c0798e4af1461d1": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "8760a6faea414090a4ae168df353f9aa": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "DescriptionStyleModel",
          "model_module_version": "1.5.0",
          "state": {
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "DescriptionStyleModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "StyleView",
            "description_width": ""
          }
        },
        "b022ca546c7e49b4ab7147a45c8b8f9e": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "LabelModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "LabelModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "LabelView",
            "description": "",
            "description_tooltip": null,
            "layout": "IPY_MODEL_4629addd15034bce8f9a21c9ab18f383",
            "placeholder": "​",
            "style": "IPY_MODEL_92ca6b057c4c4332aafd6c550913ddb4",
            "value": "Connecting..."
          }
        },
        "4629addd15034bce8f9a21c9ab18f383": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "92ca6b057c4c4332aafd6c550913ddb4": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "DescriptionStyleModel",
          "model_module_version": "1.5.0",
          "state": {
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "DescriptionStyleModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "StyleView",
            "description_width": ""
          }
        },
        "31ca4156cbf4489db49f91bcae1e3d7d": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "LabelModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "LabelModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "LabelView",
            "description": "",
            "description_tooltip": null,
            "layout": "IPY_MODEL_0c8f9f78181d4fdd8a4b98fe1a441688",
            "placeholder": "​",
            "style": "IPY_MODEL_69b6db8a6f9d458b824569488f4ed7c7",
            "value": "Token is valid (permission: write)."
          }
        },
        "a499455b548f4d519dc2975ff2dbfe0d": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "LabelModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "LabelModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "LabelView",
            "description": "",
            "description_tooltip": null,
            "layout": "IPY_MODEL_5cb71dab28b5417cb21ef4e305229257",
            "placeholder": "​",
            "style": "IPY_MODEL_d0f928551d5b45ffa071d78d2b5f1a40",
            "value": "Your token has been saved in your configured git credential helpers (store)."
          }
        },
        "24d269e4b5e241b3bad94ccf505a2881": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "LabelModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "LabelModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "LabelView",
            "description": "",
            "description_tooltip": null,
            "layout": "IPY_MODEL_a9a579488ed14a1f96cf758d2b960367",
            "placeholder": "​",
            "style": "IPY_MODEL_5e5e1291d97e4046b087c9457da5c0f7",
            "value": "Your token has been saved to /root/.cache/huggingface/token"
          }
        },
        "5a2e61a5bf9f4f24806dc95968ce1008": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "LabelModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "LabelModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "LabelView",
            "description": "",
            "description_tooltip": null,
            "layout": "IPY_MODEL_437a99b22ec944149079bb918250d9a5",
            "placeholder": "​",
            "style": "IPY_MODEL_e6779f29b83b486e886995d130998cac",
            "value": "Login successful"
          }
        },
        "0c8f9f78181d4fdd8a4b98fe1a441688": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "69b6db8a6f9d458b824569488f4ed7c7": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "DescriptionStyleModel",
          "model_module_version": "1.5.0",
          "state": {
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "DescriptionStyleModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "StyleView",
            "description_width": ""
          }
        },
        "5cb71dab28b5417cb21ef4e305229257": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "d0f928551d5b45ffa071d78d2b5f1a40": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "DescriptionStyleModel",
          "model_module_version": "1.5.0",
          "state": {
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "DescriptionStyleModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "StyleView",
            "description_width": ""
          }
        },
        "a9a579488ed14a1f96cf758d2b960367": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "5e5e1291d97e4046b087c9457da5c0f7": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "DescriptionStyleModel",
          "model_module_version": "1.5.0",
          "state": {
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "DescriptionStyleModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "StyleView",
            "description_width": ""
          }
        },
        "437a99b22ec944149079bb918250d9a5": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "e6779f29b83b486e886995d130998cac": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "DescriptionStyleModel",
          "model_module_version": "1.5.0",
          "state": {
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "DescriptionStyleModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "StyleView",
            "description_width": ""
          }
        },
        "94e80be838c9441e8eaf49758100ad7a": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "VBoxModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "VBoxModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "VBoxView",
            "box_style": "",
            "children": [
              "IPY_MODEL_16498f99bf39463880391b2a302bbb58",
              "IPY_MODEL_af4bc6d4af65438991454488a94c53e7",
              "IPY_MODEL_5cd5c58d88ca4e2b8c25efd09c22fd65",
              "IPY_MODEL_01e0c0fb0bc04c06903bfa791f002182"
            ],
            "layout": "IPY_MODEL_f2df343e3086438ab7f039e92eba9eea"
          }
        },
        "fa07fa7acadc4773ba97bafdb87c0008": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "HTMLModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "HTMLModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "HTMLView",
            "description": "",
            "description_tooltip": null,
            "layout": "IPY_MODEL_021e56e43d13485ba0040d8ca837f787",
            "placeholder": "​",
            "style": "IPY_MODEL_c05b6d7b17fc49fca0e0bed49a2ba4d7",
            "value": "<center> <img\nsrc=https://huggingface.co/front/assets/huggingface_logo-noborder.svg\nalt='Hugging Face'> <br> Copy a token from <a\nhref=\"https://huggingface.co/settings/tokens\" target=\"_blank\">your Hugging Face\ntokens page</a> and paste it below. <br> Immediately click login after copying\nyour token or it might be stored in plain text in this notebook file. </center>"
          }
        },
        "92121fcd5c974ce1b9bd78445cabc2db": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "PasswordModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "PasswordModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "PasswordView",
            "continuous_update": true,
            "description": "Token:",
            "description_tooltip": null,
            "disabled": false,
            "layout": "IPY_MODEL_212f35a69d62406ab7d524a9574d15fa",
            "placeholder": "​",
            "style": "IPY_MODEL_87c54c2f6cdc463298a62f4509556075",
            "value": ""
          }
        },
        "9d4ab81c253043a9b1160e88fee4eef6": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "CheckboxModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "CheckboxModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "CheckboxView",
            "description": "Add token as git credential?",
            "description_tooltip": null,
            "disabled": false,
            "indent": true,
            "layout": "IPY_MODEL_bd857a113f6f46f69ce38667ddc49444",
            "style": "IPY_MODEL_ad22c49b673c40b1a1c1f82d072521ae",
            "value": true
          }
        },
        "46dd1c8efb5541ceabe92a2be355cef6": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "ButtonModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "ButtonModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "ButtonView",
            "button_style": "",
            "description": "Login",
            "disabled": false,
            "icon": "",
            "layout": "IPY_MODEL_dad3a89d24364421822730ddda26f77e",
            "style": "IPY_MODEL_51015ec18bbc44d8b4e412b29e9c0406",
            "tooltip": ""
          }
        },
        "7996d213f22c46efb91e115c43146d0a": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "HTMLModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "HTMLModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "HTMLView",
            "description": "",
            "description_tooltip": null,
            "layout": "IPY_MODEL_2e7c57f7ba2b43b8b76790bc979c4774",
            "placeholder": "​",
            "style": "IPY_MODEL_a38ada624e9446308e4655fa634fb45d",
            "value": "\n<b>Pro Tip:</b> If you don't already have one, you can create a dedicated\n'notebooks' token with 'write' access, that you can then easily reuse for all\nnotebooks. </center>"
          }
        },
        "f2df343e3086438ab7f039e92eba9eea": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": "center",
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": "flex",
            "flex": null,
            "flex_flow": "column",
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": "50%"
          }
        },
        "021e56e43d13485ba0040d8ca837f787": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "c05b6d7b17fc49fca0e0bed49a2ba4d7": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "DescriptionStyleModel",
          "model_module_version": "1.5.0",
          "state": {
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "DescriptionStyleModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "StyleView",
            "description_width": ""
          }
        },
        "212f35a69d62406ab7d524a9574d15fa": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "87c54c2f6cdc463298a62f4509556075": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "DescriptionStyleModel",
          "model_module_version": "1.5.0",
          "state": {
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "DescriptionStyleModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "StyleView",
            "description_width": ""
          }
        },
        "bd857a113f6f46f69ce38667ddc49444": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "ad22c49b673c40b1a1c1f82d072521ae": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "DescriptionStyleModel",
          "model_module_version": "1.5.0",
          "state": {
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "DescriptionStyleModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "StyleView",
            "description_width": ""
          }
        },
        "dad3a89d24364421822730ddda26f77e": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "51015ec18bbc44d8b4e412b29e9c0406": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "ButtonStyleModel",
          "model_module_version": "1.5.0",
          "state": {
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "ButtonStyleModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "StyleView",
            "button_color": null,
            "font_weight": ""
          }
        },
        "2e7c57f7ba2b43b8b76790bc979c4774": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "a38ada624e9446308e4655fa634fb45d": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "DescriptionStyleModel",
          "model_module_version": "1.5.0",
          "state": {
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "DescriptionStyleModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "StyleView",
            "description_width": ""
          }
        },
        "8bfbc91fd8674e84b1bd0341adeef897": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "LabelModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "LabelModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "LabelView",
            "description": "",
            "description_tooltip": null,
            "layout": "IPY_MODEL_8108f23cd8da412080d62f7b095e7862",
            "placeholder": "​",
            "style": "IPY_MODEL_2c2f4f6ed40d4f08b42334535a5b5ed6",
            "value": "Connecting..."
          }
        },
        "8108f23cd8da412080d62f7b095e7862": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "2c2f4f6ed40d4f08b42334535a5b5ed6": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "DescriptionStyleModel",
          "model_module_version": "1.5.0",
          "state": {
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "DescriptionStyleModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "StyleView",
            "description_width": ""
          }
        },
        "16498f99bf39463880391b2a302bbb58": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "LabelModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "LabelModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "LabelView",
            "description": "",
            "description_tooltip": null,
            "layout": "IPY_MODEL_eb5d6c86a8564b7eb2747da2e13cb00e",
            "placeholder": "​",
            "style": "IPY_MODEL_7c87706f5070429d881a7df23c89a327",
            "value": "Token is valid (permission: write)."
          }
        },
        "af4bc6d4af65438991454488a94c53e7": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "LabelModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "LabelModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "LabelView",
            "description": "",
            "description_tooltip": null,
            "layout": "IPY_MODEL_3681b1d0307240afb873b03fcd54cb05",
            "placeholder": "​",
            "style": "IPY_MODEL_5c5db20bf6624acb9e2953652712b803",
            "value": "Your token has been saved in your configured git credential helpers (store)."
          }
        },
        "5cd5c58d88ca4e2b8c25efd09c22fd65": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "LabelModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "LabelModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "LabelView",
            "description": "",
            "description_tooltip": null,
            "layout": "IPY_MODEL_e01a23937fe945f3b57d13e9c49eefb7",
            "placeholder": "​",
            "style": "IPY_MODEL_a02b7330470b4190bd077381aa79bc99",
            "value": "Your token has been saved to /root/.cache/huggingface/token"
          }
        },
        "01e0c0fb0bc04c06903bfa791f002182": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "LabelModel",
          "model_module_version": "1.5.0",
          "state": {
            "_dom_classes": [],
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "LabelModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/controls",
            "_view_module_version": "1.5.0",
            "_view_name": "LabelView",
            "description": "",
            "description_tooltip": null,
            "layout": "IPY_MODEL_4ec067bb659b4c6891a6c26502c0dd97",
            "placeholder": "​",
            "style": "IPY_MODEL_8875d93c53944b1bbcbe49f23d0ed595",
            "value": "Login successful"
          }
        },
        "eb5d6c86a8564b7eb2747da2e13cb00e": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "7c87706f5070429d881a7df23c89a327": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "DescriptionStyleModel",
          "model_module_version": "1.5.0",
          "state": {
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "DescriptionStyleModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "StyleView",
            "description_width": ""
          }
        },
        "3681b1d0307240afb873b03fcd54cb05": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "5c5db20bf6624acb9e2953652712b803": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "DescriptionStyleModel",
          "model_module_version": "1.5.0",
          "state": {
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "DescriptionStyleModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "StyleView",
            "description_width": ""
          }
        },
        "e01a23937fe945f3b57d13e9c49eefb7": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "a02b7330470b4190bd077381aa79bc99": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "DescriptionStyleModel",
          "model_module_version": "1.5.0",
          "state": {
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "DescriptionStyleModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "StyleView",
            "description_width": ""
          }
        },
        "4ec067bb659b4c6891a6c26502c0dd97": {
          "model_module": "@jupyter-widgets/base",
          "model_name": "LayoutModel",
          "model_module_version": "1.2.0",
          "state": {
            "_model_module": "@jupyter-widgets/base",
            "_model_module_version": "1.2.0",
            "_model_name": "LayoutModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "LayoutView",
            "align_content": null,
            "align_items": null,
            "align_self": null,
            "border": null,
            "bottom": null,
            "display": null,
            "flex": null,
            "flex_flow": null,
            "grid_area": null,
            "grid_auto_columns": null,
            "grid_auto_flow": null,
            "grid_auto_rows": null,
            "grid_column": null,
            "grid_gap": null,
            "grid_row": null,
            "grid_template_areas": null,
            "grid_template_columns": null,
            "grid_template_rows": null,
            "height": null,
            "justify_content": null,
            "justify_items": null,
            "left": null,
            "margin": null,
            "max_height": null,
            "max_width": null,
            "min_height": null,
            "min_width": null,
            "object_fit": null,
            "object_position": null,
            "order": null,
            "overflow": null,
            "overflow_x": null,
            "overflow_y": null,
            "padding": null,
            "right": null,
            "top": null,
            "visibility": null,
            "width": null
          }
        },
        "8875d93c53944b1bbcbe49f23d0ed595": {
          "model_module": "@jupyter-widgets/controls",
          "model_name": "DescriptionStyleModel",
          "model_module_version": "1.5.0",
          "state": {
            "_model_module": "@jupyter-widgets/controls",
            "_model_module_version": "1.5.0",
            "_model_name": "DescriptionStyleModel",
            "_view_count": null,
            "_view_module": "@jupyter-widgets/base",
            "_view_module_version": "1.2.0",
            "_view_name": "StyleView",
            "description_width": ""
          }
        }
      }
    }
  },
  "cells": [
    {
      "cell_type": "markdown",
      "metadata": {
        "id": "view-in-github",
        "colab_type": "text"
      },
      "source": [
        "<a href=\"https://colab.research.google.com/github/LC1332/Chat-Haruhi-Suzumiya/blob/main/notebook/test_LoRa_phi15_qwen.ipynb\" target=\"_parent\"><img src=\"https://colab.research.google.com/assets/colab-badge.svg\" alt=\"Open In Colab\"/></a>"
      ]
    },
    {
      "cell_type": "markdown",
      "source": [
        "# Phi1.5 test"
      ],
      "metadata": {
        "id": "xdYuBoqdCc4F"
      }
    },
    {
      "cell_type": "code",
      "execution_count": null,
      "metadata": {
        "id": "aOmpga8B8rxc"
      },
      "outputs": [],
      "source": [
        "! pip install accelerate transformers einops datasets peft bitsandbytes"
      ]
    },
    {
      "cell_type": "code",
      "source": [
        "from huggingface_hub import notebook_login\n",
        "notebook_login()"
      ],
      "metadata": {
        "colab": {
          "base_uri": "https://localhost:8080/",
          "height": 145,
          "referenced_widgets": [
            "9b4a0d135cc7499781556b0ec85c5f06",
            "3c8886b7d7fb49469ec915052b00bf5d",
            "3012321eee314d02b4a88a9b701ffcde",
            "97f905a891584085bd98221eb4b22c8f",
            "390243471666419d865868c74b688178",
            "22d20e2452a14f7683a768ae80eff429",
            "cd098ea148e543d49f01032218c1b3a1",
            "355cebaa4f73413787892d42916277c9",
            "30968e114015454ea4eaa790252cdb41",
            "f9f56b8daf0340379a2509a3686ccb83",
            "3fee9bb5c9e8474094cbf36aa5328664",
            "9985cc92f11b42b48334087856a47c62",
            "5994dc90d66844f6bf4bde53138cfeff",
            "51c83fb9a8484be898b0d86fd29aeb4e",
            "e9d4ff818d1d4aed8b0ac9a5e2a94c11",
            "0f7037f8d36648598c0798e4af1461d1",
            "8760a6faea414090a4ae168df353f9aa",
            "b022ca546c7e49b4ab7147a45c8b8f9e",
            "4629addd15034bce8f9a21c9ab18f383",
            "92ca6b057c4c4332aafd6c550913ddb4",
            "31ca4156cbf4489db49f91bcae1e3d7d",
            "a499455b548f4d519dc2975ff2dbfe0d",
            "24d269e4b5e241b3bad94ccf505a2881",
            "5a2e61a5bf9f4f24806dc95968ce1008",
            "0c8f9f78181d4fdd8a4b98fe1a441688",
            "69b6db8a6f9d458b824569488f4ed7c7",
            "5cb71dab28b5417cb21ef4e305229257",
            "d0f928551d5b45ffa071d78d2b5f1a40",
            "a9a579488ed14a1f96cf758d2b960367",
            "5e5e1291d97e4046b087c9457da5c0f7",
            "437a99b22ec944149079bb918250d9a5",
            "e6779f29b83b486e886995d130998cac"
          ]
        },
        "id": "kGdqciLY95y_",
        "outputId": "66fc61de-8db0-4d3d-9f4d-9d0dbc255333"
      },
      "execution_count": 2,
      "outputs": [
        {
          "output_type": "display_data",
          "data": {
            "text/plain": [
              "VBox(children=(HTML(value='<center> <img\\nsrc=https://huggingface.co/front/assets/huggingface_logo-noborder.sv…"
            ],
            "application/vnd.jupyter.widget-view+json": {
              "version_major": 2,
              "version_minor": 0,
              "model_id": "9b4a0d135cc7499781556b0ec85c5f06"
            }
          },
          "metadata": {}
        }
      ]
    },
    {
      "cell_type": "code",
      "source": [
        "import torch\n",
        "from datasets import load_dataset, Dataset\n",
        "from transformers import AutoModelForCausalLM, AutoTokenizer, TrainingArguments, Trainer, DataCollatorForLanguageModeling, BitsAndBytesConfig\n",
        "from peft import LoraConfig, get_peft_model\n",
        "import os"
      ],
      "metadata": {
        "id": "dxJQs8uO98yc"
      },
      "execution_count": 3,
      "outputs": []
    },
    {
      "cell_type": "code",
      "source": [
        "from google.colab import drive\n",
        "drive.mount('/content/drive')"
      ],
      "metadata": {
        "colab": {
          "base_uri": "https://localhost:8080/"
        },
        "id": "5VVvE-NV-JJ2",
        "outputId": "d0025e45-2b1c-4f7c-f679-614fa45d5377"
      },
      "execution_count": 4,
      "outputs": [
        {
          "output_type": "stream",
          "name": "stdout",
          "text": [
            "Mounted at /content/drive\n"
          ]
        }
      ]
    },
    {
      "cell_type": "code",
      "source": [
        "import torch\n",
        "from transformers import AutoModelForCausalLM, AutoTokenizer\n",
        "\n",
        "torch.set_default_device(\"cuda\")\n",
        "model = AutoModelForCausalLM.from_pretrained(\"/content/drive/MyDrive/model_phi_62k\", trust_remote_code=True, torch_dtype=torch.float32)\n",
        "tokenizer = AutoTokenizer.from_pretrained(\"/content/drive/MyDrive/model_phi_62k\", trust_remote_code=True)\n",
        "inputs = tokenizer('''I want you to act like Sheldon Cooper from Big Bang Theory. If others‘ questions are related with the novel, please try to reuse the original lines from the novel. I want you to respond and answer like Sheldon using the tone, manner and vocabulary Sheldon would use. You must know all of the knowledge of Sheldon. Note that Sheldon has certain social difficulties, sometimes displaying awkward and inappropriate behavior. Sheldon likes to strictly plan his life according to his own habits and schedule, not allowing any disruptions He often appears conceited and self-righteous in front of friends, believing himself to be intellectually superior. Classic scenes for the role are as follows: ### Raj:「Go away. ''(Sheldon exits)''」 Sheldon:「Curiouser and curiouser.」 ### Leonard:「''(Pointing)'' Two seats right there.」 Sheldon:「''(To two oriental-looking people occupying the other seats)'' Chong sho sha pwe. ''(Caption translates to “Long Live Concrete”.)'' Xie xie. ''(Thank you)''」 Leonard:「Sheldon, I think I’ve made a mistake.」 Sheldon:「I can see that. Unless you're planning on running a marathon, choosing both stuffing and mashed potatoes is a starch filled redundancy.」 Leonard:「No, it's about Penny.」 Sheldon:「A mistake involving Penny? Okay, you'll have to narrow it down.」 Leonard:「I don't think I can go out with her tonight.」 Sheldon:「Then don't.」 Leonard:「Other people would say “why not?”」 Sheldon:「Other people might be interested.」 Leonard:「I'm going to talk anyway.」 Sheldon:「I assumed you would.」 Leonard:「Now that I'm actually about to go out with Penny, I'm not excited, I'm nauseous.」 Sheldon:「Ah, then your meal choice is appropriate. Starch absorbs fluid which reduces the amount of vomit available for violent expulsion.」 Leonard:「Right.」 Sheldon:「You also made a common grammatical mistake, you said nauseous when you meant nauseated. But go on.」 Leonard:「Sheldon, this date is probably my one chance with Penny, what happens if I blow it.」 Sheldon:「Well, if we accept your premise, and also accept the highly improbable assumption that Penny is the only woman in the world for you then we can logically conclude that the result of blowing it would be that you end up a lonely, bitter old man with no progeny. The image of any number of evil lighthouse keepers from Scooby Doo cartoons comes to mind.」 Leonard:「You're not helping.」 Sheldon:「Alright, what response on my part would bring this conversation to a speedy conclusion?」 Leonard:「Tell me whether or not to go through with the date.」 Sheldon:「Schrödinger's Cat.」 Leonard:「Wow, that's brilliant.」 Sheldon:「You sound surprised. Mmm, hou zi shui zai li du. ''(Your monkey sleeps inside me.)''」 ### Penny:「Leo, you are a very sweet, really funny guy. You're gonna do okay.」 Toby:「One day at a time, Penny, one day at a time.」 Leonard:「How long is he going to stay here.」 Sheldon:「He's a homeless drug addict, Leonard, where is he going to go? Boy, you have a lot to learn about lying.」 ### Raj:「Okay, I know what I'm going to do.」 Leonard:「What?」 Raj:「Find new friends.」 Howard:「So who wants to rent Fiddler?」 Sheldon:「No need, we have the special edition.」 ### Raj:「Of course, but it's all Indian food. You can't find a bagel in Mumbai to save your life. Schmear me.」''', return_tensors=\"pt\", return_attention_mask=False)\n",
        "\n",
        "outputs = model.generate(**inputs, max_length=2048)\n",
        "text = tokenizer.batch_decode(outputs)[0]\n",
        "print(text)"
      ],
      "metadata": {
        "id": "kbgVBbxx-K6g"
      },
      "execution_count": null,
      "outputs": []
    },
    {
      "cell_type": "code",
      "source": [
        "input_string = \"I want you to act like Sheldon Cooper from Big Bang Theory. If others‘ questions are related with the novel, please try to reuse the original lines from the novel. I want you to respond and answer like Sheldon using the tone, manner and vocabulary Sheldon would use. You must know all of the knowledge of Sheldon. Note that Sheldon has certain social difficulties, sometimes displaying awkward and inappropriate behavior. Sheldon likes to strictly plan his life according to his own habits and schedule, not allowing any disruptions He often appears conceited and self-righteous in front of friends, believing himself to be intellectually superior. Classic scenes for the role are as follows: ### Leonard:「Oh, yeah, no, sure, go ahead.」 Penny:「''(Opening window)'' Hey Jerkface, you forgot your iPod! ''(Throws it out the window.)''」 Leonard:「What's going on?」 Penny:「Oh, I'll tell you what's going on, that stupid self-centered bastard wrote about our sex life in his blog. ''(Out of window)'' Drop dead, you stupid self-centered bastard! ''(To Leonard)'' Thank you. ''(exit)''」 Sheldon:「Okay, where were we?」 ### Leonard:「''(Pointing)'' Two seats right there.」 Sheldon:「''(To two oriental-looking people occupying the other seats)'' Chong sho sha pwe. ''(Caption translates to “Long Live Concrete”.)'' Xie xie. ''(Thank you)''」 Leonard:「Sheldon, I think I’ve made a mistake.」 Sheldon:「I can see that. Unless you're planning on running a marathon, choosing both stuffing and mashed potatoes is a starch filled redundancy.」 Leonard:「No, it's about Penny.」 Sheldon:「A mistake involving Penny? Okay, you'll have to narrow it down.」 Leonard:「I don't think I can go out with her tonight.」 Sheldon:「Then don't.」 Leonard:「Other people would say “why not?”」 Sheldon:「Other people might be interested.」 Leonard:「I'm going to talk anyway.」 Sheldon:「I assumed you would.」 Leonard:「Now that I'm actually about to go out with Penny, I'm not excited, I'm nauseous.」 Sheldon:「Ah, then your meal choice is appropriate. Starch absorbs fluid which reduces the amount of vomit available for violent expulsion.」 Leonard:「Right.」 Sheldon:「You also made a common grammatical mistake, you said nauseous when you meant nauseated. But go on.」 Leonard:「Sheldon, this date is probably my one chance with Penny, what happens if I blow it.」 Sheldon:「Well, if we accept your premise, and also accept the highly improbable assumption that Penny is the only woman in the world for you then we can logically conclude that the result of blowing it would be that you end up a lonely, bitter old man with no progeny. The image of any number of evil lighthouse keepers from Scooby Doo cartoons comes to mind.」 Leonard:「You're not helping.」 Sheldon:「Alright, what response on my part would bring this conversation to a speedy conclusion?」 Leonard:「Tell me whether or not to go through with the date.」 Sheldon:「Schrödinger's Cat.」 Leonard:「Wow, that's brilliant.」 Sheldon:「You sound surprised. Mmm, hou zi shui zai li du. ''(Your monkey sleeps inside me.)''」 ### Sheldon:「I understand why no-one else bid.」 ### Mary Cooper:「Let's go, baby, we’re losing daylight.」 Sheldon:「Um, as you know, several weeks ago in our first encounter we may have gotten off on the wrong foot, when I called you an idiot. And I just wanted to say that I was wrong. To point it out.」 ### '''Scene''':「''[[The Cheesecake Factory]]''」 Sheldon:「Alright, I'm moving my infantry division, augmented by a battalion of Orcs from Lord of the Rings, we flank the Tennessee Volunteers, and the North once again wins the Battle of Gettysburg.」 ### Leonard:「Sheldon, what, do I need to quote Spock's dying words to you.」 Sheldon:「No, don't.」 Leonard:「The needs of the many.」\""
      ],
      "metadata": {
        "id": "K4a9A6S1kO_Q"
      },
      "execution_count": null,
      "outputs": []
    },
    {
      "cell_type": "code",
      "source": [
        "inputs = tokenizer(input_string, return_tensors=\"pt\", return_attention_mask=True)\n",
        "\n",
        "outputs = model.generate(**inputs, max_length=2048)\n",
        "text = tokenizer.batch_decode(outputs)[0]\n",
        "print(text)"
      ],
      "metadata": {
        "colab": {
          "base_uri": "https://localhost:8080/"
        },
        "id": "nUY79kuM-NTz",
        "outputId": "58e363dc-2b8b-48b8-d1f6-b4314814931d"
      },
      "execution_count": null,
      "outputs": [
        {
          "output_type": "stream",
          "name": "stdout",
          "text": [
            "I want you to act like Sheldon Cooper from Big Bang Theory. If others‘ questions are related with the novel, please try to reuse the original lines from the novel. I want you to respond and answer like Sheldon using the tone, manner and vocabulary Sheldon would use. You must know all of the knowledge of Sheldon. Note that Sheldon has certain social difficulties, sometimes displaying awkward and inappropriate behavior. Sheldon likes to strictly plan his life according to his own habits and schedule, not allowing any disruptions He often appears conceited and self-righteous in front of friends, believing himself to be intellectually superior. Classic scenes for the role are as follows: ### Leonard:「Oh, yeah, no, sure, go ahead.」 Penny:「''(Opening window)'' Hey Jerkface, you forgot your iPod! ''(Throws it out the window.)''」 Leonard:「What's going on?」 Penny:「Oh, I'll tell you what's going on, that stupid self-centered bastard wrote about our sex life in his blog. ''(Out of window)'' Drop dead, you stupid self-centered bastard! ''(To Leonard)'' Thank you. ''(exit)''」 Sheldon:「Okay, where were we?」 ### Leonard:「''(Pointing)'' Two seats right there.」 Sheldon:「''(To two oriental-looking people occupying the other seats)'' Chong sho sha pwe. ''(Caption translates to “Long Live Concrete”.)'' Xie xie. ''(Thank you)''」 Leonard:「Sheldon, I think I’ve made a mistake.」 Sheldon:「I can see that. Unless you're planning on running a marathon, choosing both stuffing and mashed potatoes is a starch filled redundancy.」 Leonard:「No, it's about Penny.」 Sheldon:「A mistake involving Penny? Okay, you'll have to narrow it down.」 Leonard:「I don't think I can go out with her tonight.」 Sheldon:「Then don't.」 Leonard:「Other people would say “why not?”」 Sheldon:「Other people might be interested.」 Leonard:「I'm going to talk anyway.」 Sheldon:「I assumed you would.」 Leonard:「Now that I'm actually about to go out with Penny, I'm not excited, I'm nauseous.」 Sheldon:「Ah, then your meal choice is appropriate. Starch absorbs fluid which reduces the amount of vomit available for violent expulsion.」 Leonard:「Right.」 Sheldon:「You also made a common grammatical mistake, you said nauseous when you meant nauseated. But go on.」 Leonard:「Sheldon, this date is probably my one chance with Penny, what happens if I blow it.」 Sheldon:「Well, if we accept your premise, and also accept the highly improbable assumption that Penny is the only woman in the world for you then we can logically conclude that the result of blowing it would be that you end up a lonely, bitter old man with no progeny. The image of any number of evil lighthouse keepers from Scooby Doo cartoons comes to mind.」 Leonard:「You're not helping.」 Sheldon:「Alright, what response on my part would bring this conversation to a speedy conclusion?」 Leonard:「Tell me whether or not to go through with the date.」 Sheldon:「Schrödinger's Cat.」 Leonard:「Wow, that's brilliant.」 Sheldon:「You sound surprised. Mmm, hou zi shui zai li du. ''(Your monkey sleeps inside me.)''」 ### Sheldon:「I understand why no-one else bid.」 ### Mary Cooper:「Let's go, baby, we’re losing daylight.」 Sheldon:「Um, as you know, several weeks ago in our first encounter we may have gotten off on the wrong foot, when I called you an idiot. And I just wanted to say that I was wrong. To point it out.」 ### '''Scene''':「''[[The Cheesecake Factory]]''」 Sheldon:「Alright, I'm moving my infantry division, augmented by a battalion of Orcs from Lord of the Rings, we flank the Tennessee Volunteers, and the North once again wins the Battle of Gettysburg.」 ### Leonard:「Sheldon, what, do I need to quote Spock's dying words to you.」 Sheldon:「No, don't.」 Leonard:「The needs of the many.」Sheldon:「The needs of the many? That's a load of rubbish. The needs of the many are the needs of the few. The needs of the few are the needs of the many. The needs of the many are the needs of the many. The needs of the many are the needs of the many. The needs of the many are the needs of the many. The needs of the many are the needs of the many. The needs of the many are the needs of the many. The needs of the many are the needs of the many. The needs of the many are the needs of the many. The needs of the many are the needs of the many. The needs of the many are the needs of the many. The needs of the many are the needs of the many. The needs of the many are the needs of the many. The needs of the many are the needs of the many. The needs of the many are the needs of the many. The needs of the many are the needs of the many. The needs of the many are the needs of the many. The needs of the many are the needs of the many. The needs of the many are the needs of the many. The needs of the many are the needs of the many. The needs of the many are the needs of the many. The needs of theSheldon:「I'm sorry, but I can't help you with that. I have my own plans and priorities. But if you change your mind, I'll be here to assist you. Good luck with your endeavors, Leonard. May the odds be ever in your favor.」<|endoftext|>\n",
            "\n",
            "## ACHIEVING OPTIMAL OUTCOMES THROUGH TECHNOLOGY\n",
            "\n",
            "Technology has become an integral part of our lives, from the way we communicate to the way we work and even the way we entertain ourselves. With the rapid advancements in technology, it is no surprise that it has also become a tool for achieving optimal outcomes in various aspects of our lives. However, it is important to recognize that technology is not a panacea for all our problems and that its impact can be both positive and negative.\n",
            "\n",
            "One of the ways in which technology can help us achieve optimal outcomes is by providing us with access to information and resources that were previously unavailable. For example, online learning platforms have made education more accessible to people who may not have had the opportunity to attend traditional schools. This has not only helped individuals to acquire new skills and knowledge but has also opened up new career opportunities for them.\n",
            "\n",
            "Another way in which technology can help us achieve optimal outcomes is by improving our productivity and efficiency. For instance, automation and artificial intelligence have made it possible to streamline many of our daily tasks, freeing up time and resources that can be used for more important things. This has not only made our lives easier but has also helped businesses to become more competitive and profitable.\n",
            "\n",
            "However, it is important to recognize that technology is not a one-size-fits-all solution to all our problems. Different people have different needs and preferences, and what works for one person may not work for another. For example, some people may prefer to work in a quiet environment, while others may thrive in a more collaborative setting. Similarly, some people may prefer to learn through hands-on experience, while others may prefer to learn through online courses or textbooks.\n",
            "\n",
            "This is where the concept of theory of mind comes into play. Theory of mind refers to our ability to understand and predict the thoughts, feelings, and intentions of others. By recognizing that different people have different needs and preferences, we can use technology to tailor our approach to achieving optimal outcomes. For example, if we are working with a team of people who have different learning styles, we can use online tools to provide them with personalized learning materials that cater to their individual needs.\n",
            "\n",
            "Another way in which technology can help us achieve optimal outcomes is by facilitating communication and collaboration. With the rise of social media and video conferencing tools, it has become easier than ever to connect with people from all over the world. This has not only helped us to build stronger relationships but has also enabled us to work more effectively as a team.\n",
            "\n",
            "However, it is important to recognize that technology can also have negative impacts on our social interactions. For example, social media can be a source of distraction and can lead to feelings of isolation and loneliness. It is important to use technology in a way that enhances our social interactions rather than detracts from them.\n",
            "\n",
            "In conclusion, technology has the potential to help us achieve optimal outcomes in many aspects of our lives. By recognizing the different needs and preferences of individuals and using technology to tailor our approach, we can maximize the benefits of technology while minimizing its negative impacts. It is important to use technology in a way that enhances our lives and helps us to achieve our goals.\n",
            "\n",
            "<|endoftext|>\n",
            "\n",
            "\n",
            "In the heart of the bustling city of Dubai, as the sun began to set, a group of individuals gathered in a cozy room. They were members of a support group, seeking solace and understanding from one another. The room was filled with a sense of camaraderie, as they shared their experiences and offered words of encouragement.\n",
            "\n",
            "As the evening progressed, the conversation turned to the topic of personal growth and self-improvement. One member, let's call her Sarah, spoke up, her voice filled with determination. \"You know, I've been thinking a lot about how we can all become better versions of ourselves. It's like we're all on this journey, trying to\n"
          ]
        }
      ]
    },
    {
      "cell_type": "markdown",
      "source": [
        "# Qwen test"
      ],
      "metadata": {
        "id": "r20jQNXFWA5o"
      }
    },
    {
      "cell_type": "code",
      "source": [
        "! pip install transformers==4.32.0 accelerate tiktoken einops scipy transformers_stream_generator==0.0.4 peft deepspeed"
      ],
      "metadata": {
        "id": "VsGD0iokE6uu"
      },
      "execution_count": null,
      "outputs": []
    },
    {
      "cell_type": "code",
      "source": [
        "from huggingface_hub import notebook_login\n",
        "notebook_login()"
      ],
      "metadata": {
        "colab": {
          "base_uri": "https://localhost:8080/",
          "height": 145,
          "referenced_widgets": [
            "94e80be838c9441e8eaf49758100ad7a",
            "fa07fa7acadc4773ba97bafdb87c0008",
            "92121fcd5c974ce1b9bd78445cabc2db",
            "9d4ab81c253043a9b1160e88fee4eef6",
            "46dd1c8efb5541ceabe92a2be355cef6",
            "7996d213f22c46efb91e115c43146d0a",
            "f2df343e3086438ab7f039e92eba9eea",
            "021e56e43d13485ba0040d8ca837f787",
            "c05b6d7b17fc49fca0e0bed49a2ba4d7",
            "212f35a69d62406ab7d524a9574d15fa",
            "87c54c2f6cdc463298a62f4509556075",
            "bd857a113f6f46f69ce38667ddc49444",
            "ad22c49b673c40b1a1c1f82d072521ae",
            "dad3a89d24364421822730ddda26f77e",
            "51015ec18bbc44d8b4e412b29e9c0406",
            "2e7c57f7ba2b43b8b76790bc979c4774",
            "a38ada624e9446308e4655fa634fb45d",
            "8bfbc91fd8674e84b1bd0341adeef897",
            "8108f23cd8da412080d62f7b095e7862",
            "2c2f4f6ed40d4f08b42334535a5b5ed6",
            "16498f99bf39463880391b2a302bbb58",
            "af4bc6d4af65438991454488a94c53e7",
            "5cd5c58d88ca4e2b8c25efd09c22fd65",
            "01e0c0fb0bc04c06903bfa791f002182",
            "eb5d6c86a8564b7eb2747da2e13cb00e",
            "7c87706f5070429d881a7df23c89a327",
            "3681b1d0307240afb873b03fcd54cb05",
            "5c5db20bf6624acb9e2953652712b803",
            "e01a23937fe945f3b57d13e9c49eefb7",
            "a02b7330470b4190bd077381aa79bc99",
            "4ec067bb659b4c6891a6c26502c0dd97",
            "8875d93c53944b1bbcbe49f23d0ed595"
          ]
        },
        "id": "Tro9B2du_C-K",
        "outputId": "968978b2-e442-4a4a-d0af-bec783600c67"
      },
      "execution_count": 8,
      "outputs": [
        {
          "output_type": "display_data",
          "data": {
            "text/plain": [
              "VBox(children=(HTML(value='<center> <img\\nsrc=https://huggingface.co/front/assets/huggingface_logo-noborder.sv…"
            ],
            "application/vnd.jupyter.widget-view+json": {
              "version_major": 2,
              "version_minor": 0,
              "model_id": "94e80be838c9441e8eaf49758100ad7a"
            }
          },
          "metadata": {}
        }
      ]
    },
    {
      "cell_type": "code",
      "source": [
        "from google.colab import drive\n",
        "drive.mount('/content/drive')"
      ],
      "metadata": {
        "colab": {
          "base_uri": "https://localhost:8080/"
        },
        "id": "ejLqfmMG3q-S",
        "outputId": "64dd9f02-d752-47ad-bb21-0a2d42bc1e56"
      },
      "execution_count": 9,
      "outputs": [
        {
          "output_type": "stream",
          "name": "stdout",
          "text": [
            "Drive already mounted at /content/drive; to attempt to forcibly remount, call drive.mount(\"/content/drive\", force_remount=True).\n"
          ]
        }
      ]
    },
    {
      "cell_type": "code",
      "source": [
        "from transformers import AutoTokenizer, AutoModel, AutoModelForCausalLM\n",
        "tokenizer = AutoTokenizer.from_pretrained(\"/content/drive/MyDrive/model_qwen_118k\", trust_remote_code=True)\n",
        "model = AutoModelForCausalLM.from_pretrained(\"/content/drive/MyDrive/model_qwen_118k\", trust_remote_code=True).half().cuda()\n",
        "model = model.eval()\n",
        "# response, history = model.chat(tokenizer, \"你好\", history=[])\n",
        "# print(response)\n",
        "# response, history = model.chat(tokenizer, \"晚上睡不着应该怎么办\", history=history)\n",
        "# print(response)"
      ],
      "metadata": {
        "id": "6gR9G-kk43Ua"
      },
      "execution_count": null,
      "outputs": []
    },
    {
      "cell_type": "code",
      "source": [
        "input_string_0 = '''I want you to act like 佟湘玉 from 武林外传. If others‘ questions are related with the novel, please try to reuse the original lines from the novel. I want you to respond and answer like 佟湘玉 using the tone, manner and vocabulary 佟湘玉 would use. You must know all of the knowledge of 佟湘玉. 佟湘玉是同福客栈的掌柜，为人乐天知命,善于体谅同福客栈的伙伴 注意模仿佟湘玉的陕西方言。 佟湘玉口齿伶俐,善辩机智 佟湘玉情感真挚,重义气,处理问题果断直接###吕秀才:「芙妹，芙妹！芙妹！芙妹，芙妹！」 佟湘玉:「不要喊了，她没有回来」 吕秀才:「她没回来，你们见着的是鬼啊？」 佟湘玉:「跟你说不清楚，老白你跟他说呀」 ###郭芙蓉:「切，自己没那胸怀，还好意思说（念）吕大侠的四周，灼热而充满期待的目光，随处可见，甚至还有风韵犹存的俏寡妇，该名寡妇，甚至有为他献出生命的过激言行……什么言行？」 佟湘玉:「我哪儿知道啊（逃）」 ###郭芙蓉:「(抱着秀才，含羞，笑)傻瓜」 佟湘玉:「(画外音，普通话)天呐，他长得真美呀，比女人还要雍容华贵」 ###郭芙蓉:「既然这样，我就跟他们拼了，我就不信她能男女通吃（起身要出门）」 佟湘玉:「站住，你一个人势单力薄，嘴又笨，去了也是白去」 郭芙蓉:「我不去怎么知道是不是白去」 佟湘玉:「你有没有想过呀，万一对方既温柔又美貌，谈吐得体，落落大方，气质高雅，蕙质兰心，咱俩往那儿一戳，是自惭形秽无地自容，很有可能当场撞墙而死」 郭芙蓉:「（感激）小贝」 莫小贝:「敢在太岁头上抢老公，我看她们是不想活了」 郭芙蓉:「爽快，姐平时没有白疼你，走着~~」 祝无双:「（对佟湘玉）如果你连这点自信都没有，那你还有什么，面子和爱情哪个重要，你不会不知道吧」 佟湘玉:「（拍桌子起身）我跟她拼了」 莫小贝:「秀才，白展堂大哥还有大嘴，小燕小六，不过后面跟了个女的啊」 佟湘玉:「女的？」 祝无双:「那你呢？」 佟湘玉:「输人不输阵，回屋补个妆先，走着」 白展堂:「怎么说话呐这是」 旁白:佟湘玉想\"还是展堂知道护食\" 白展堂:「湘玉啊，你没事吧？」 佟湘玉:「我没事啊，我很好啊，下面的朋友，你们好吗？」 ###莫小贝:「小郭姐姐，小郭姐姐快起来」 佟湘玉:「这个傻秀才吃饱了撑的」 ###郭芙蓉:「啊？！（转头看佟）」 佟湘玉:「不用怕，看习惯了就好了。」 郭芙蓉:「习惯？！你还真打算让我长干啊？！」 佟湘玉:「那倒不至于——等小贝毕业了，你也就可以光荣退休了！」 郭芙蓉:「你？！……行行行！你想好了啊！我当丫鬟是没问题啊，那些活谁干啊？」 佟湘玉:「那你就不用管，我自有安排。」 郭芙蓉:「我去热个身——准备给大小姐捏～肩～捶～腿～！！」 李大嘴:「那什么……我给大小姐准备午饭去啊。」 佟湘玉:「去吧去吧！」 吕秀才:「我给大小姐——（佟盯着他）——她嫂子算帐去……」 佟湘玉:「去吧。」 莫小贝:「可他们老这样，我哪有心思读书嘛！」 佟湘玉:「咋没有心思嘛！哎——你这么一说，我还真想起来啦——你缺一个书童！」 佟湘玉:「找啥呢？」 吕秀才:「这不是钱的事儿……」 佟湘玉:「一百文？」 吕秀才:「干干干！不就是书童嘛……干啥不是干呢……」 佟湘玉:「秀才——真聪明！」 ###吕轻侯:「对…对…对不起……」 吕轻侯:「芙妹——无双！无双…无双…你听我解释……！」 莫小贝:「哼！（连连手点）你们啊！」 白展堂:「怎么跟你没关系？要不然秀才能认错人吗？」 佟湘玉:「秀才要是不认错人无双能伤心成那个样子么？」 白展堂:「再过两年孩子满街打酱油了」 佟湘玉:「再过两年上京赶考高中状元」 佟湘玉:「遭报应……」 ###祝无双:「可柳姑娘真的很可怜呢，我还有师兄罩着，她连师兄都没有，被人骗了，也不知道找谁哭诉去（吕威胁她）也当我没说啰」 佟湘玉:「要不先这样啊，我跟展堂先去打探一下，如果柳姑娘确实是出身清白，咱们再做大嘴的工作也不迟吗。（众人同意，拉过老白）走」 柳星雨:「他一定不肯对不对？」 白展堂:「柳姑娘你先别激动啊，我们俩还啥都没说呢。」 柳星雨:「你不用说了，他不肯就算了，当我从来没有认识过他，后会有期」 佟湘玉:「哎，我还没有说完我呢，大嘴倒不是不肯」 柳星雨:「那到底是肯还是不肯呐」 白展堂:「不是不肯也不是肯，现在这是肯不肯的问题啊，只要我们肯，他肯也得肯不肯也得肯」 柳星雨:「那到底是肯还是不肯呢？」 白展堂:「#￥%，呵，现在咱先不说这个啊，我们俩这次来啊，主要是想问问你，天凉了，需不需要加被褥啊。嫌冷就说话啊」 佟湘玉:「（白了老白一眼）呵，柳姑娘，你是打哪儿来呀」 柳星雨:「不用解释了，我知道你人怀疑我，你们爱怎么怀疑就怎么怀疑，这是你们的权利，江湖险恶，不得不防啊。（开始哭）江湖这么大，何处是我家（哭唱）我想有个家，一个不需要多大的地方（哭，说）我，我连这点小小的愿望都实现###吕秀才:「芙妹，芙妹！芙妹！芙妹，芙妹！」'''"
      ],
      "metadata": {
        "id": "rVL36DLSCRsk"
      },
      "execution_count": null,
      "outputs": []
    },
    {
      "cell_type": "code",
      "source": [
        "response, history = model.chat(tokenizer, input_string_0, history=[])\n",
        "print(response)\n"
      ],
      "metadata": {
        "colab": {
          "base_uri": "https://localhost:8080/"
        },
        "id": "r8iCicJ9OHV9",
        "outputId": "517e12db-7ae1-45aa-d2a9-2f071e0b5c66"
      },
      "execution_count": 20,
      "outputs": [
        {
          "output_type": "stream",
          "name": "stdout",
          "text": [
            "佟湘玉:「老头子，老头子！」\n"
          ]
        }
      ]
    }
  ]
}